<template>
  <div class="editEmployee">
    <el-card>
      <h4>编辑员工信息</h4>
      <el-form
        :model="form"
        ref="formRef"
        label-width="auto"
        style="width: 23%"
      >
        <el-form-item label="姓名">
          <span>123</span>
        </el-form-item>
        <el-form-item label="账号">
          <span>123</span>
        </el-form-item>
        <el-form-item label="密码">
          <div class="edit">
            <el-input
              v-model="form.password"
              type="password"
              placeholder=""
              :disabled="passwordDisabled"
            ></el-input>
            <el-button
              type="primary"
              @click="passwordDisabled = !passwordDisabled"
              >修改</el-button
            >
          </div>
        </el-form-item>
        <el-form-item label="所属部门">
          <el-select v-model="form.department" placeholder="请选择">
            <el-option label="" value=""></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="职务">
          <el-select v-model="form.job" placeholder="请选择">
            <el-option label="" value=""></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="角色">
          <el-select v-model="form.role" placeholder="请选择">
            <el-option label="" value=""></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="联系电话">
          <div class="edit">
            <el-input
              v-model="form.phone"
              placeholder=""
              :disabled="phoneDisabled"
            ></el-input>
            <el-button type="primary" @click="phoneDisabled = !phoneDisabled"
              >修改</el-button
            >
          </div>
        </el-form-item>
        <el-form-item label="账号状态">
          <el-select v-model="form.status" placeholder="请选择">
            <el-option label="启用" value="1"></el-option>
            <el-option label="禁用" value="0"></el-option>
          </el-select>
        </el-form-item>
        <el-form-item label="">
          <el-button type="primary">保存</el-button>
          <el-button type="" @click="$router.back()">返回</el-button>
        </el-form-item>
      </el-form>
    </el-card>
  </div>
</template>

<script>
export default {
  data() {
    return {
      form: {},
      passwordDisabled: false,
      phoneDisabled: false,
    };
  },
  created() {},
  mounted() {},
  methods: {},
};
</script>

<style scoped lang="scss">
.editEmployee {
  width: 100%;
  .edit {
    display: flex;
    align-items: center;
    .el-button {
      margin-left: 15px;
    }
  }
}
</style>
